{layout layout_main.html}
{php}
$form = Admin::run()->article();
{/php}
<h3>编辑文章<a href="article.html" class="actionBtn">文章列表</a></h3>
<form action="" method="post" enctype="multipart/form-data" class="formBasic" onsubmit="ajaxForm(this,callback_ajax,true);return false;">
	<table width="100%" border="0" cellpadding="8" cellspacing="0" class="tableBasic">
		<tr>
			<td width="80" align="right">文章分类</td>
			<td>
				<select name="form[cat_id]" style="width:auto;" data-default="{$form['cat_id']}">
					<option value="">-无-</option>
					{loop Admin::run()->article_categorys() $k $v}
					<option value="{$v['cat_id']}" {php}echo $form['cat_id']==$v['cat_id']?'selected':'';{/php}>{$v['cat_name']}</option>
					{/loop}
				</select>
			</td>
		</tr>
		<tr>
			<td align="right">页面别名</td>
			<td><input type="text" name="form[filename]" id="" value="{$form['filename']}" size="50" class="inpMain"/></td>
		</tr>
		<tr>
			<td align="right">页面URI</td>
			<td><input type="text" name="form[uri]" id="" value="{$form['uri']}" size="50" class="inpMain"/></td>
		</tr>
		<tr>
			<td align="right">排序</td>
			<td><input type="text" name="form[sort]" id="" value="{$form['sort']}" size="10" class="inpMain"/></td>
		</tr>
		<tr>
			<td align="right">标题</td>
			<td><input type="text" name="form[title]" id="" value="{$form['title']}" size="50" class="inpMain"/></td>
		</tr>
		<tr>
			<td align="right">关键词</td>
			<td><input type="text" name="form[keywords]" id="" value="{$form['keywords']}" size="50" class="inpMain"/></td>
		</tr>
		<tr>
			<td align="right">页面描述</td>
			<td><textarea name="form[description]" placeholder="description" rows="3" cols="52" class="inpMain">{$form['description']}</textarea></td>
		</tr>
		<tr>
			<td align="right">关键词</td>
			<td><input type="text" name="form[tag]" id="" value="{$form['tag']}" size="50" class="inpMain" placeholder="tag1,tag2,tag3,..." title="多个标签之间使用英文半角逗号分隔" /></td>
		</tr>
		<tr>
			<td align="right">Banner横幅</td>
			<td>
				<input type="hidden" name="form[banner]" value="{$form['banner']}" data-file="form_banner[]" />
				<input type="file" name="form_banner[]" multiple="multiple" class="inpFlie" onchange="ajaxFileUpload(this,location.href,{'act':'admin/file_upload'},callback_ajax,'jpg|jpeg|png|gif')" /> <span>(支持多文件)</span>
				<div data-imgs="form_banner[]">
					{if $form['banner']}{loop explode(',',$form['banner']) $k $v}
					<div class="imgs">
						<img src="{$v}" width="100" height="100">
						<div class="del-img" onclick="del_data_imgs(this)">删除</div>
					</div>
					{/loop}{/if}
				</div>
			</td>
		</tr>
		<tr>
			<td align="right">缩略图</td>
			<td>
				<input type="hidden" name="form[image]" value="{$form['image']}" data-file="form_file[]" />
				<input type="file" name="form_file[]" multiple="multiple" class="inpFlie" onchange="ajaxFileUpload(this,location.href,{'act':'admin/file_upload'},callback_ajax,'jpg|jpeg|png|gif')" /> <span>(支持多文件)</span>
				<div data-imgs="form_file[]">
					{if $form['image']}{loop explode(',',$form['image']) $k $v}
					<div class="imgs">
						<img src="{$v}" width="100" height="100">
						<div class="del-img" onclick="del_data_imgs(this)">删除</div>
					</div>
					{/loop}{/if}
				</div>
			</td>
		</tr>
		<tr>
			<td align="right">页面内容</td>
			<td>{Admin::run()->html_editor('form[content]',$form['content'])}</td>
		</tr>
		<tr>
			<td align="right">自定义属性</td>
			<td><textarea name="form[defined]" placeholder="" rows="3" cols="52" class="inpMain">{$form['defined']}</textarea></td>
		</tr>
		<tr>
			<td align="right">发布时间</td>
			<td><input type="text" name="form[add_time]" id="" value="{$form['add_time']?date('Y-m-d H:i:s',$form['add_time']):date('Y-m-d H:i:s')}" size="50" class="inpMain"/></td>
		</tr>
		<tr>
			<td align="right"></td>
			<td>
				<input type="hidden" name="act" value="admin/article_save" />
				<input type="hidden" name="form[id]" value="{intval($form['id'])}" />
				<input name="submit" class="btn" type="submit" value="提交">
			</td>
		</tr>
	</table>
</form>